﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using HNQXYJ.Model;
using HNQXYJ.DAL;
namespace HNQXYJ.HN_DATA
{
    public partial class WebForm1 : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {

        }

        protected void Button1_Click(object sender, EventArgs e)
        {
            EquipOnline eo = new EquipOnline();
            eo.Phone = "13600000000";
            eo.DateAdd = DateTime.Now.ToString("yyyy-MM-dd");
            eo.OnLine00 = 1;
            int res = new EquipOnLineDAL().AddDataOnTime00(eo,"1");
            if (res > 0)
            {
                this.Label1.Text = "插入成功";
            }
        }

        protected void Button2_Click(object sender, EventArgs e)
        {
            EquipOnline eo = new EquipOnline();
            eo.Phone = "13600000000";
            eo.DateAdd = DateTime.Now.ToString("yyyy-MM-dd");
            int hourNum = 06;
            int res = new EquipOnLineDAL().UpdateOnHour(eo,hourNum);
            if (res > 0)
            {
                this.Label1.Text = "插入成功";
            }
        }
    }
}